package com.emep.changzhi.analyse.entity.outlet;

import com.emep.changzhi.analyse.entity.basics.SysCompanyInfo;
import lombok.Data;
import org.hibernate.annotations.GenericGenerator;

import javax.persistence.*;
import java.util.Date;

/**
 * @author Wangcc
 * @version V1.0
 * @Description: 排口信息表
 * @date 2018/2/26 14:37
 */
@Data
@Table(name = "sys_outlet_info")
@Entity
public class SysOutletInfo {

    @Id
    @GenericGenerator(name = "system-uuid" , strategy = "uuid")
    @GeneratedValue(generator = "system-uuid")
    private String id;

    @ManyToOne(cascade={CascadeType.MERGE,CascadeType.REFRESH},fetch=FetchType.EAGER,optional=false)
    @JoinColumn(name="company_id")
    private SysCompanyInfo company;

    @Column(name = "outlet_type",columnDefinition="varchar(100) COMMENT '排口类别'"  )
    private String outletType;

    @Column(name = "outlet_name",columnDefinition="varchar(100) COMMENT '排放口名称'" )
    private String outletName;

    @Column(name = "longitude",columnDefinition="varchar(100) COMMENT '排放口经度'" )
    private String longitude;

    @Column(name = "latitude",columnDefinition="varchar(100) COMMENT '排放口纬度'" )
    private String latitude;

    @Column(name = "outlet_status",columnDefinition="varchar(100) COMMENT '排放口运行状态'" )
    private String outletStatus;

    @Column(name = "outlet_access",columnDefinition="varchar(100) COMMENT '排放量数值获取方式'" )
    private String outletAccess;

    @Column(name = "unified_code",columnDefinition="varchar(100) COMMENT '排口唯一编码'" )
    private String unifiedCode;

    @Column(name = "is_delete",columnDefinition="varchar(100) COMMENT '删除状态'" )
    private String isDelete = "0";

    @Column(name = "pollute_type",columnDefinition="varchar(100) COMMENT '污染类型'" )
    private String polluteType;

    @Column(name = "create_date",columnDefinition="varchar(100) COMMENT '信息录入时间'" )
    private String createDate = String.valueOf(System.currentTimeMillis());



}

